﻿@{
    ViewBag.Title = "数据恢复";
}
<!DOCTYPE html>
@model ElingOA6_Admin_DSJCJ.Model.Rc
<html>
@Html.Partial("LoadPanelPartial")
<head>
    @if (false)
    {
        <script src="../../../../Scripts/jquery-vsdoc.js" type="text/javascript"></script>
    }
    <link href="@Url.Content("~/Content/Site.css", true)" rel="stylesheet" type="text/css" />
    <script src="@Url.Content("~/Scripts/jquery.min.js", true)" type="text/javascript"></script>
    <script src="@Url.Content("~/Common/GetRootPath.ashx", true)" type="text/javascript"></script>

    @Html.DevExpress().GetStyleSheets(

        new StyleSheet { ExtensionType = ExtensionType.ListBox, Theme = DevExpressHelper.Theme }
)
    @Html.DevExpress().GetScripts(
        new Script { ExtensionType = ExtensionType.ListBox }
)
    <script type="text/javascript">
        $(document).ready(function () {
            var hdjsAlert = $("#hidMessage").val();
            var hdjsAlert2 = $("#hidIsClose").val();
            if (hdjsAlert != "") {
                alert(hdjsAlert);
                if (hdjsAlert2 == "Y") {
                    window.returnValue = 'SUCCESS';
                    window.close();
                }
            }
        });

        function ok() {
            if (upload.GetText() == "") {
                alert("请选择要上传的文件！");
            } else {
                if (confirm("确定要恢复数据吗")) {
                    form1.submit();                              
                }
             }            
         }

        function cancel() {
            window.location.href = rootPath + "/Admin/Fwmmsjhf";
        
         }

    </script>



</head>
<body>
<script type="text/javascript">
    if (top.boardtop) top.boardtop.head_txt.innerText = "数据恢复";

</script>
    @using (Html.BeginForm("SaveFwmmsjhf", "Fwmmsjhf", FormMethod.Post, new { id = "form1" }))
    {
        <br />
        <div class="div">
        <table width="99%" align="center" class="tableForm">
            <tr>
                <th align="right" width="20%">
                    操作说明:</th>
                <td class="tdClass">
                    <br />
                    数据恢复一定要是ZIP压缩包！<br />
                    数据恢复由于数据过大时间比较缓慢，请耐心等待！
                    <br />
                </td>
            </tr>
            <tr>
                <th>
                选择操作:
                </th>
                <td valign="bottom" class="tbClass">
                     @Html.DevExpress().UploadControl(
                        settings =>
                        {
                            settings.Name = "upload";
                            settings.BrowseButton.Text = "浏览";
                            settings.Height = System.Web.UI.WebControls.Unit.Percentage(100);
                            settings.ClearFileSelectionImage.ToolTip = "清除选择";
                            settings.ShowProgressPanel = true;
                            settings.ValidationSettings.MaxFileSize = 20971520;                           
                            settings.ShowUploadButton = false;
                        }).GetHtml()
                </td>
            </tr>
            <tr>
            <th>数据最后导入时间:</th>
            <td class="tdClass">
                @Html.DevExpress().Label(settings => {
                     settings.Text = Model.value == "" ? "暂时没有此项操作" : DateTime.Parse(Model.value).ToString("yyyy.MM.dd HH:mm");   
                }).GetHtml()
            </td>
            </tr>
            <tr>
                <th></th>
                <td>

                @Html.DevExpress().Button(settings =>
            {
                settings.Name = "btnOK";
                settings.Text = "确定";
                settings.ControlStyle.CssClass = "button";
                settings.Images.Image.Url = Url.Content("~/Content/ControlImages/ok.png");
                settings.ClientSideEvents.Click = "ok";
            }).GetHtml()
                @Html.DevExpress().Button(settings =>
            {
                settings.Name = "btnCancel";
                settings.Text = "取消";
                settings.ControlStyle.CssClass = "button";
                settings.Images.Image.Url = Url.Content("~/Content/ControlImages/no.png");
                settings.CausesValidation = false;
                settings.ClientSideEvents.Click = "cancel";

            }).GetHtml()
            </td>
            </tr>
            
        </table>
    </div>
         @Html.Hidden("hidMessage", ViewData["message"])
         @Html.Hidden("hidIsClose", ViewData["IsClose"])

    }
    <script>
        lp.Hide();
    </script>

</body>
</html>
